package com.k2091.washcar.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 
 * </p>
 *
 * @author author
 * @since 2021-06-02
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("users")
public class Users implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @TableField("name")
    private String name;

    @TableField("password")
    private String password;

    /**
     * 1正常  2冻结
     */
    @TableField("status")
    private Integer status;

    @TableField("balance")
    private Double balance;

    @TableField("gender")
    private Integer gender;

    /**
     * 身份证号
     */
    @TableField("id_number")
    private String idNumber;

    /**
     * 手机号
     */
    @TableField("mobile")
    private String mobile;

    @TableField("createtime")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createtime;

    @TableField("last_login")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime lastLogin;

    /**
     * 对应微信表id
     */
    @TableField("wechat_id")
    private Long wechatId;


    /**
     * 年龄
     */
    @TableField("age")
    private Integer age;


}
